package editro.view 
{
	import editro.events.system.AddNewTaskViewItemEvent;
	import editro.events.system.SystemEvent;
	import editro.model.AntTaskVOListModel;
	import editro.view.components.AntTaskView;
	import editro.view.components.TaskViewsContainer;
	import org.robotlegs.mvcs.Mediator;
	
	/**
	 * ...
	 * @author LEEF LEE_LEAF918@163.COM_QQ969442267
	 */
	public class TaskViewsContainerMediator extends Mediator 
	{
		[Inject] 
		public var view:TaskViewsContainer;
		
		public function TaskViewsContainerMediator() 
		{
			
		}
		
		override public function onRegister():void 
		{
			super.onRegister();
			eventMap.mapListener(eventDispatcher, AddNewTaskViewItemEvent.ADD_TASK_ITEM_TO_STAGE, addTaskViewToContainer);
		}
		
		private function addTaskViewToContainer(e:AddNewTaskViewItemEvent):void 
		{
			var o:AntTaskView = new AntTaskView
			view.addChild(o);
			
		}
		
	}

}